/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package cz.muni.fi.pb138.videodes.impl;

import cz.muni.fi.pb138.videodes.entity.Dvd;
import cz.muni.fi.pb138.videodes.entity.DvdType;
import java.util.List;

/**
 * DVD manager stores and retrieves DVDs from the database.
 *
 * @author pseudo
 */
public interface DvdManager {
    /**
     * Stores DVD in the database.
     * @param dvd stored DVD
     */
    public void add(Dvd dvd);

    /**
     * Removes DVD form the database.
     * @param dvd removed DVD
     */
    public void remove(Dvd dvd);
    
    /**
     * Updates DVD stored in database.
     * @param dvd  updated DVD
     */
    public void update(Dvd dvd);

    /**
     * Gets all DVDs from the database.
     * 
     * @return List of all DVDs retrieved from the database.
     */
    public List<Dvd> getAllDvds();
	
    /**
     * Gets a DVD depending on the given ID.
     * 
     * @param id id of the DVD
     * @return DVD with the given ID
     */
    public Dvd getDvdById(String id);

    /**
     * Gets DVDs depending on the given type.
     * 
     * @param type type of DVDs
     * @return List of DVDs with the specified type retrieved from the database.
     */
    public List<Dvd> getDvdsByType(DvdType type);
}
